package com.wkbb.common.enums;

/**
 * IM操作群成员类型
 */
public enum ImOperGroupTypeEnum {
    /**
     * 入群
     */
    IN_GROUP(1,"入群"),

    /**
     * 退群
     */
    OUT_GROUP(2,"退群");

    private ImOperGroupTypeEnum(Integer value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    private Integer value;

    private String desc;

    public Integer getValue() {
        return this.value;
    }

    public void setValue(Integer value) {
        this.value = value;
    }

    public String getDesc() {
        return this.desc;
    }

    public void setDesc(String desc) {
        this.desc = desc;
    }

    public static String getDesc(Integer value) {
        for (ImOperGroupTypeEnum operGroupType : ImOperGroupTypeEnum.values()) {
            if (operGroupType.getValue().intValue()==value) {
                return operGroupType.getDesc();
            }
        }
        return null;
    }
}
